import { stringify } from 'qs';
import request from '@/utils/request';
// 监控系统美股期权监控接口
export async function Upload(monitorData) {
  return request(`fss/OptionMonitorTrading/Upload`, {
    method: 'POST',
    body: JSON.stringify(monitorData),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
// export async function DelMonitor() {
//   return request(`fss/optionmonitor/clear`, {
//     method: 'POST',
//     headers: {
//       'Content-Type': 'application/json;charset=utf-8',
//     },
//   });
// }
export async function GetByDate(data) {
  return request(`fss/OptionMonitorTrading/GetByDate`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function TurnOverMonitorList(data) {
  return request(`fss/OptionMonitorTrading/TurnOverMonitorList`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function GetDateList() {
  return request(`/fss/OptionMonitorTrading/GetDateList`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function tradingUpdateOption(data) {
  return request(`fss/OptionMonitorTrading/UpdateOption`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function AddNewOption(data) {
  return request(`fss/OptionMonitorTrading/AddNewOption`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function clear(data) {
  return request(`fss/OptionMonitorTrading/clear`, {
    method: 'POST',
    // body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function Delete(data) {
  return request(`fss/OptionMonitorTrading/Delete`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}

// 盘中期权接口
// export async function TradingUploadOrder(monitorData) {
//   return request(`fss/optionmonitor/TradingUploadOrder`, {
//     method: 'POST',
//     body: JSON.stringify(monitorData),
//     headers: {
//       'Content-Type': 'application/json;charset=utf-8',
//     },
//   });
// }

// export async function TradingGetList(data) {
//   return request(`fss/optionmonitor/TradingGetList`, {
//     method: 'POST',
//     body: JSON.stringify(data),
//     headers: {
//       'Content-Type': 'application/json;charset=utf-8',
//     },
//   });
// }
// export async function TradingGetByDate(data) {
//   return request(`fss/optionmonitor/TradingGetByDate`, {
//     method: 'POST',
//     body: JSON.stringify(data),
//     headers: {
//       'Content-Type': 'application/json;charset=utf-8',
//     },
//   });
// }
// export async function TradingGetDateList() {
//   return request(`/fss/optionmonitor/TradingGetDateList`, {
//     method: 'POST',
//     headers: {
//       'Content-Type': 'application/json;charset=utf-8',
//     },
//   });
// }

// 监控系统美股个股监控接口
export async function aUploadcode(data) {
  return request(`fss/optionmonitor/uploadcode`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function getcodelist(data) {
  return request(`fss/optionmonitor/codelist`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function clearcode(data) {
  return request(`fss/optionmonitor/codeclear`, {
    method: 'POST',
    // body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
// AI交易信号
export async function UploadCountTopBottom(data) {
  return request(`fss/TradingSignal/UploadCountTopBottom`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
export async function CountTopBottom(data) {
  return request(`fss/TradingSignal/CountTopBottom`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
      // "Content-Type":"application/x-www-form-urlencoded"
    },
  });
}

export async function codeDateList(data) {
  return request(`/fss/optionmonitor/CodeDateList`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
      // "Content-Type":"application/x-www-form-urlencoded"
    },
  });
}

export async function UpdateOption(data) {
  return request(`fss/optionmonitor/UpdateOption`, {
    method: 'POST',
    body: JSON.stringify(data),
    headers: {
      'Content-Type': 'application/json;charset=utf-8',
    },
  });
}
